from flask import Flask

def create_app():
    app=Flask(__name__)
    app.config.from_object('app.config.secure')
    app.config.from_object('app.config.setting')
    reginster(app)
    regster_plugin(app)
    return app

def reginster(app):
    from app.front.all import front
    app.register_blueprint(front)

def regster_plugin(app):
    from .exts import db
    db.init_app(app)
